home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Software Vault: The Gold Collection
/
Software Vault - The Gold Collection (American Databankers) (1993).ISO
/
cdr49
/
136_01.zip
/
TERMINAL.DOC
< prev
next >
Wrap
Text File
|
1993-06-01
|
10KB
|
241 lines
/* HEADER: CUG136.16;
TITLE: TERMINAL;
DATE: 7/1/86;
DESCRIPTION: "Terminal installation program documentation";
SYSTEM: CP/M;
FILENAME: TERMINAL.DOC;
AUTHORS: R. Rodman;
*/
This disk contains games
and a (quasi-)universal terminal definition system. Before
running any of the other programs, run TERMINAL to create the
file TERMINAL.
Other terminal configuration methods
described in your newsletter don't allow for object code
portability, whereas this one does and has been used with not
only C but also BASIC, Pascal and assembler. The games were fun
projects of mine and I've decided to put them all into the public
domain. I only learned C recently, so two were converted from
Basic, the other from assembler (Don't criticize my C too much!
Give me a chance!). They are written in C/80 (Software
Toolworks), which means they should be easily portable to any
Unix-compatible C.
Here is a listing of the files on the disk:
DUMPSTAR.C, .SUB, .COM - Dump Star video game
TZ.C, .R, .COM, .DOC - Twilight Zone adventure game
NO FAIR READING TZ.R! (Maybe we ought to squeeze it?)
CMAZE.C, .SUB, .COM - Perspective maze game
(Careful - doesn't use TERMINAL.SYS; also does direct
port I/O to an AY-3-9513 Cricket at ports B0,B1 hex)
TERMINAL.C, .COM, .DOC - Terminal configuration program
RDTERM.C, .COM - Check your terminal configuration
RANDOM.C - Random function for C/80
PORTIO.C - I/O port access for C/80
CUG.LTR - this letter
Someone can probably improve upon my random number generator. It
is pretty crude. If anyone installs any terminals beyond what
TERMINAL supports, I'd like to get a copy of the new values so
that the program can be enhanced.
.pa
Other projects I have underway are a 68000 cross-assembler and an
operating system. Once the cross-assembler is complete I want to
make a small-C for the 68000 which will then be used with the
operating system as well as other projects. Currently the
operating system is in Z80 assembler. When this is finished it
will all become public domain. If anyone is working on similar
projects, I'd sure like to get in touch with them.
Have fun and ... C you later!
Richard Rodman
6607 Mayfair Drive #302
Falls Church VA 22042
(703) 241-1681
.FOThird Planet Productions, P.O. Box 3268, McLean VA 22103
HOW TO CONFIGURE OUR PROGRAMS
FOR YOUR SYSTEM -
All Third Planet Productions programs are configured by means of
a universal Terminal File. This file is read by programs written
in BASIC, PASCAL and assembler, and will be used in all future
TPP software releases as well. The programmers out there are
encouraged to use it as well.
The first step in configuring the program is to find out
WHAT KIND OF TERMINAL YOU HAVE.
If you have a Televideo 950, STOP! That's the default.
There is a library of terminal configurations which comes with
the program (TERMINAL.LIC). Your terminal/computer might be in
the library already.
The configurations currently supported are:
TeleVideo 920 TeleVideo 950 Visual 200 Heath H19
Osborne I ANSI Standard MAX-80 Hazeltine
Perkin-Elmer Fox DEC VT-52
If the configuration you need is not in the library, you will
need to get your terminal manual and look up your control
sequences. Some of the terminals included in the library are
listed here a little later. Backed up by this, you're ready to
bring up the TERMINAL program (TERMINAL.COM). This is done as
follows:
A>TERMINAL (Double width shows what you type in)
Which console do you wish to configure? In a single-user system,
it's always console 0 (zero). In multi-user MP/M configurations,
each console may be a different terminal type.
If you can use one of the configurations supplied in the library
then use the R option in the program. When you select R you will
be asked if you wish to configure for a variety of terminals. If
you don't wish to use a particular configuration answer N;
otherwise answer Y and the program will be set to use that
terminal/computer. It's that simple!
If there isn't an entry in the library that applies to your
machine then you will need to use the C option. Control
characters should be entered as a ^ (caret) followed by the
upper-case letter. For example, control-R would be entered as
^R. In particular, the escape code (ESC) would be entered as ^[.
The Home command for a Televideo would be entered as ^^.
Few of the programs use all of the various entries in the file.
Most will operate with just the Clear Screen and Cursor
Addressing parameters.
.pa
After you enter your codes you might want to enter them into the
library for future use. You can do this with the A option. (You
might want to test your configuration before putting it into the
library. If so,then you can test it using the method explained
in the next paragraph. Then you can reenter TERMINAL and add
your settings to the library.)
You can test how well your terminal is configured by running the
RDTERM program:
A>RDTERM
The various messages printed test what they say they are testing.
(Honest!)
If you are unable to decipher your terminal manual, please feel
free to write us. In fact, when you order programs in the
future, mention the type of terminal you have, and we may be able
to pass along some information on how to configure it better for
our software. Also if you have a configuration that we do not
support, we would appreciate hearing from you: either in the
questionaire, your next order or in a separate note.)
.PA
TERMINAL FILE FORMAT
This document describes the file format of the standard terminal
definition file. This file is generated by a program called
TERMINAL.COM and is named TERMINAL.SYS.
The file has a record length of 128 characters, divided into 16
8-byte fields. There is one record for each console in the
system. Each field consists of a 0 to 7 ASCII characters, padded
with at least one null. If the function is unavailable, the
first byte should be a null.
In most cases, the entire field can be printed. In the case of
cursor addressing, this is not advisable. The following BASIC
function can be used to truncate the field string:
DEF FNS$(O$)=LEFT$(O$,INSTR(O$,CHR$(0))-1)
Field Mnemonic Description
1 Miscellaneous parameters:
WIDTH 1 Screen width in columns (1 byte)
HEIGHT 2 Screen height in lines (1 byte)
DEFINT 3 Default intensity: 'L'=Low 'H'=High
USELST 4 Use last: 'Y'=Can print in last position
without scrolling
Cursor addressing parameters:
SNDFST 5 Send first: 'Y' or 'X'
METHOD 6 Method: '0'=Binary
'1'=ASCII-Decimal, req'd no. of chars
'2'=ASCII-Decimal, 2 characters
'3'=ASCII-Decimal, 3 characters
XADD 7 X addend
YADD 8 Y addend
2 INISTR Initialization string
(put terminal into ANSI mode, etc.)
3 CLRSCN Clear Screen
4 CLREOS Clear to end of screen
5 CLREOL Clear to end of line
6 CUROFF Turn cursor off
7 CURON Turn cursor on
8 CURBEG Cursor addressing - Lead-in
9 CURMID Cursor addressing - between X and Y
10 CUREND Cursor addressing - Trailer
11 HIINT Begin High intensity
12 LOINT Begin Low intensity
13 REVVID Begin Reverse video
14 NORVID End Reverse Video
15 INSLIN Insert Line
16 DELLIN Delete Line
.pa
Some Typical Terminals
The following are some of the settings for the terminals that are
in the terminal library. When entering your own codes, the
character ^ (caret) followed by an upper-case character will
cause the corresponding control character to be entered into the
file. Control characters should not be entered directly. Note
that TERMINAL will also display the functions in this format for
verification by the user.
Televideo Visual Heath ANSI
TVI920 TVI950 200 H19 Std.
------ ------ ------ ------- ------
WIDTH 80 80 80 80 any
HEIGHT 24 24 24 24 any
DEFINT H H H H H
USELST N N N N N
SNDFST Y Y Y Y Y
METHOD 0 0 0 0 1
XADD 32 32 32 32 0
YADD 32 32 32 32 0
INISTR
CLRSCN ^Z ^Z ^[v ^[E ^[[2J
CLREOS ^[Y ^[Y ^[y ^[J ^[[0J
CLREOL ^[T ^[T ^[x ^[K ^[[0K
CUROFF ^[.0 ^[x5 ^[[5h
CURON ^[.2 ^[y5 ^[[5l
CURBEG ^[= ^[= ^[Y ^[Y ^[[
CURMID ;
CUREND H
HIINT ^[( ^[( ^[3 ^[[2m
LOINT ^[) ^[) ^[4 ^[[0m
REVVID ^[j ^[G4 ^[s ^[p ^[[7m
NORVID ^[k ^[G0 ^[k ^[q ^[[0m
INSLIN ^[E ^[E ^[L ^[L ^[[1L
DELLIN ^[R ^[R ^[M ^[M ^[[1M
NOTES:
The character at the end of the ANSI sequence for CURON is a
small letter L.
INISTR is not shown. To use a Heath H-19 in ANSI mode, install
as ANSI, but use ^[< for INISTR. HIINT and LOINT will not have
any visible effect on an H-19.